﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true" CodeFile="UserAccount.aspx.cs" Inherits="UserAccount" %>

<asp:Content ID="Content1" ContentPlaceHolderID="BodyContent" runat="Server">
    <div class="contentfull">
        <div class="breadcrumbs">
            <ul id="crumbs">
                <li><a title="My Account" href="#">My Account</a>
                    <img src="Content/Images/separator.png" alt="&rarr;" class="separator">
                    Settings 			</li>
            </ul>
        </div>

        <div id="showMessages">
            <%  GetMessage(); %>
        </div>

        <div class="top">
            <div class="innerleft">
                <h1>Account</h1>

                <div class="tabs_box">
                    <ul id="tabs">
                        <li><a href="#" class="tabs_on">Settings</a></li>
                        <% if (UserObject.RoleId > 0)
                           { %>
                        <li><a href="UserManagement.aspx" class="tabs_off">User Management</a></li>
                        <%}
                           if (UserObject.RoleId == 1)
                           {%>
                        <li><a href="Employee.aspx" class="tabs_off">Employee Management</a></li>
                        <%}%>
                        <li><a href="AddDevices.aspx" class="tabs_off">App Users & Devices</a></li>
                        <li><a href="DeleteAccount.aspx" class="tabs_off">Account Deactivation</a></li>

                    </ul>
                </div>
            </div>
        </div>
        <div class="content">

            <fieldset>
                <h2>Settings</h2>
                <form method="post" action="UserAccount.aspx?mode=edit">
                    <input type="hidden" name="action" value="edit2" />
                    <label for="email">First Name:</label>
                    <input type="text" class="inputed" name="fname" id="fname" value="<%= UserObject.FirstName %>" />
                    <label for="email">Last Name:</label>
                    <input type="text" class="inputed" name="lname" id="lname" value="<%= UserObject.LastName  %>" />
                    <label for="email">Phone Number:</label>
                    <input type="text" class="inputed" name="phone" id="phone" value="<%= UserObject.PhoneNumber %>" />
                    <label for="email">Email:</label>
                    <input type="text" class="inputed" name="email" id="email" value="<%= UserObject.EmailId %>" />
                    <label for="expir">Account Expiry:</label>
                    <input type="text" <%= isExpiryEnable %> class="inputed" name="expir" id="expir" value="<%= UserObject.AccountExpiry.ToString() %>" />
                    <label for="password">Password:</label>
                    <a name="password" href="ChangePassword.aspx">Change Password</a><br />
                    <label for="company">Company</label>
                    <input type="text" class="inputed" name="company" id="company" value="<%= UserObject.Company %>" />

                    <br />
                    <label class="label" for="timezone">Timezone</label>
                    <select class="inputed" name="timezone" id="timezone">
                        <%= FillTimeZoneControl() %>
                    </select>
                    <%--  *Updated Timezone will reflect once you logout and login again.--%>
                    <br />
                    <label for="expir">User Allowed:</label>
                    <input type="text" <%= isExpiryEnable %> class="inputed" name="userCount" id="userAllowed" value="<%= UserObject.DeviceLimit.ToString() %>" />
                    <br />
                    <label for="expir">Extra Mail Ids (Used for Archival Scans Mail):</label>
                    <%= this.GetEmailIds(UserObject.UserId.ToString()) %>

                    <br />
                    <input type="submit" name="updateAccountButton" value="Update Account" class="black_button blarge" />


                </form>
                <br />
            </fieldset>
        </div>
        <div style="clear: both;">&nbsp;</div>
    </div>
     <script type="text/javascript" >
         function OpenPage(url) {
             // window.open()
             window.open(url, '_blank', 'toolbar=no, scrollbars=no, resizable=no, width=450, height=450');
         }
    </script>
</asp:Content>

